package com.amado.course36ByteStream;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;

public class S01FileOutPutStreamTest {
	public static void main(String[] args) throws IOException {
		File file = new File("D:\\temp1\\temp2\\" + "abc" + ".txt");
		FileOutputStream outputStream= null;
		try {
//			outputStream = new FileOutputStream(file);
			outputStream = new FileOutputStream(file,true);
			outputStream.write("中国".getBytes());
		} catch (FileNotFoundException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}finally {
			outputStream.close();
		}
	}
}
